﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using myTwitter.BO;

namespace myTwitter.Sorting
{
    public class IMessagesAreEqualComparer : IEqualityComparer<IMessage>
    {
        #region IEqualityComparer<DirectMessage> Members

        public bool Equals(IMessage x, IMessage y)
        {
            return x.ID == y.ID;
        }

        public int GetHashCode(IMessage obj)
        {
            return obj.ToString().ToLower().GetHashCode();
        }

        #endregion
    }
}
